package com.zxh.mall.order.feign;

import com.zxh.mall.common.utils.R;
import com.zxh.mall.order.vo.OrderItemSpuInfoVO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestMapping;

import java.util.List;

/**
 * @author zhengxh
 * @version 1.0
 * @date 2024/4/4 - 04 - 04 - 13:16
 * @description com.zxh.mall.order.feign
 */

/**
 * @FeignClient指明我们要从注册中心中发现的服务的名称
 */
@FeignClient(name = "mall-product")
public interface ProductFeignService {
    @GetMapping("/product/brand/all")
    public R queryAllBrand();

    @RequestMapping("/product/spuinfo/getOrderItemSpuInfoBySpuId/{spuIds}")
    public List<OrderItemSpuInfoVO> getOrderItemSpuInfoBySpuId(@PathVariable("spuIds") Long[] spuIds);
}
